<?php

namespace app\api\controller;

/**
 * 首页接口
 */
class Index extends Base
{
    protected $noNeedLogin = ['*'];

    /**
     * 首页
     *
     */
    public function index()
    {
        //获取轮播图
        $carousel = new \app\common\model\Carousel();
        $lbt = $carousel->getList();
        if($lbt){
            foreach ($lbt as $index => &$item) {
                $item['image'] = cdnurl($item['image'], true);
            }
        }
        $this->success('请求成功',$lbt,200);
    }


}
